# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python-vine
_pkgname=vine
pkgver=5.1.0
pkgrel=6
pkgdesc='Python promises.'
arch=('any')
url='https://pypi.org/project/vine/#files'
license=('MIT')
depends=('python' 'python-case')
makedepends=('python-build' 'python-pip' 'python-wheel')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('899a494d26ce8236ba12451e8da42fad03803df0a9cf69829f650c23c0d4f6232b9246230fd984fa6616edbad8b2c08f0efe95e3692bee756dfc094f14e3432d')

build() {
  cd "$_pkgname-$pkgver"

  python -m build --wheel --outdir="$startdir/dist"
}

package() {
  cd "$_pkgname-$pkgver"

  pip install \
    --verbose \
    --disable-pip-version-check \
    --no-warn-script-location \
    --ignore-installed \
    --no-compile \
    --no-deps \
    --root="$pkgdir" \
    --prefix=/usr \
    --no-index \
    --find-links="file://$startdir/dist" \
    $_pkgname
}

